<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>求职者登录</title>
<%@include file="/view/common/js-css.jsp" %>
</head>
<body>
	<!-- 登录失败后的页面显示 -->
	<c:if test="${!empty param.loginError }">
		<div class="alert alert-danger alert-dismissible fade in" role="alert"
			style="text-align: center;">
			<button type="button" class="close" data-dismiss="alert"
				aria-label="Close">
				<span aria-hidden="true">×</span>
			</button>
			<strong>用户名或密码错误！</strong>
		</div>
	</c:if>
	<c:if test="${!empty param.registerSuccess }">
		<div class="alert alert-success alert-dismissible fade in"
			role="alert" style="text-align: center;">
			<button type="button" class="close" data-dismiss="alert"
				aria-label="Close">
				<span aria-hidden="true">×</span>
			</button>
			<strong>求职者帐号注册成功，请登录！</strong>
		</div>
	</c:if>
	<c:if test="${!empty param.sessionInvalidate }">
		<div class="alert alert-danger alert-dismissible fade in" role="alert"
			style="text-align: center;">
			<button type="button" class="close" data-dismiss="alert"
				aria-label="Close">
				<span aria-hidden="true">×</span>
			</button>
			<strong>会话已结束，请重新登录！</strong>
		</div>
	</c:if>

	<center>
		<h1>求职者登录</h1>
	</center>
	<hr>

	<form
		action="<%=request.getContextPath()%>/TalentServlet?command=login"
		method="post">
		<div class="form-group">
			<input type="text" class="form-control" name="code"
				placeholder="帐号...">
		</div>
		<div class="form-group">
			<input type="password" class="form-control" name="password"
				placeholder="密码...">
		</div>
		<input type="submit" class="btn btn-primary" value="登录" /> <input
			type="button" class="btn btn-success"
			onclick="location='<%=request.getContextPath()%>/PositionServlet?command=listAllPosition'"
			value="回到首页" />
	</form>
	<script>
		/**
		 * 操作提示
		 */
		 if ('${result}' === '1' || '${param.result}' === '1') {
			 layer.msg('操作成功~', {icon : 1}); 
		 }
		 if ('${result}' === '0' || '${param.result}' === '0') {
			 layer.msg('操作失败~', {icon : 2}); 
		 }
	</script>
</body>
</html>